package edu.langnan.xiaoli.constant;

/**
 * 返回状态码
 *
 * @author cql
 */

public enum HttpStatus {

    OK(200, "成功"),

    AccessTokenError(400, "请求参数有误"),

    NotLoginError(401, "用户未登录"),

    AuthError(402, "您没有权限操作"),

    TokenError(403, "登录过期,请重新登录"),

    NotFound(404, "资源未找到"),

    ServerError(500, "服务器繁忙,请稍后再试");


    int code;

    String message;

    HttpStatus(int code, String message) {
        this.code = code;
        this.message = message;
    }

    public int getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }
}

